<template>
	<view class="content">
展示页面
		<table>
			<tr>
				<td>ID</td>
				<td>活动名称</td>
				<td>活动价格</td>
				<td>报名截止日期</td>
				<td>参加活动时间</td>
				<td>参加活动地点</td>
				<td>活动数量</td>
				<td>已报数量</td>
				<td>活动状态</td>
				<td>创建人</td>
				<td>创建时间</td>
				<td>操作</td>
			</tr>
			
			<tr v-for="v in list">
				<td>{{v.ID}}</td>
				<td>{{v.HuoDoName}}</td>
				<td>{{v.price}}</td>
				<td>{{v.BaoMingTime}}</td>
				<td>{{v.ChanJiaTime}}</td>
				<td>{{v.Address}}</td>
				<td>{{v.num}}</td>
				<td>{{v.BaoNum}}</td>
				<td>{{v.status}}</td>
				<td>{{v.createName}}</td>
				<td>{{v.CreatedAt}}</td>
				<td>操作</td>
			</tr>

		</table>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				list : []
			}
		},
		onLoad() {
this.get_data()
		},
		methods: {
			get_data(){
				uni.request({
				    url: 'http://127.0.0.1:8080/list', //仅为示例，并非真实接口地址。
				    data: {
				    },
					method:"GET",
				    header: {
				        'content-type': 'application/x-www-form-urlencoded' //自定义请求头信息
				    },
				    success: (res) => {
				        console.log(res.data)
						this.list = res.data.Data
				        
				    }
				});
			},
		}
	}
</script>

<style>
	.content {
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;
	}

	.logo {
		height: 200rpx;
		width: 200rpx;
		margin-top: 200rpx;
		margin-left: auto;
		margin-right: auto;
		margin-bottom: 50rpx;
	}

	.text-area {
		display: flex;
		justify-content: center;
	}

	.title {
		font-size: 36rpx;
		color: #8f8f94;
	}
</style>
